<%- include('./public/header.ejs') %>
<style>
  .login {
    height: calc(100vh - 60px);
    background-color: #f1f1f1;
    display: grid;
    place-content: center;
  }

  .login form {
    width: 300px;
    height: 280px;
    background-color: #ffffff;
    box-shadow: 0 0 10px #dddddd;
    box-sizing: border-box;
    padding: 20px;
  }

  .login form .title{
    margin-bottom: 20px;
    text-align: center;
    font-weight: bold;
    color: #333333;
  }

  .login .form-item {
    height: 36px;
    box-sizing: border-box;
    border: 1px solid #ccc;
    display: flex;
    align-items: center;
    font-size: 14px;
    margin-bottom: 16px;
  }

  .login .form-item label {
    display: grid;
    place-content: center;
    width: 36px;
    font-size: 16px;
    color: #888;
  }

  .login .form-item input {
    width: calc(100% - 36px);
    height: 100%;
    border: none;
    outline: none;
  }

  .login .form-item:last-of-type input {
    width: calc(100% - 88px);
    box-sizing: border-box;
    padding-left: 14px;
  }

  .login .form-item:last-of-type img {
    width: 88px;
    height: 32px;
    cursor: pointer;
  }

  .login button {
    width: 100%;
    height: 40px;
    background-color: #409eff;
    border: none;
    border-radius: 4px;
    color: #ffffff;
    cursor: pointer;
  }
</style>
<section class="login">
    <form action="/admin/auth/doLogin" method="post">
        <p class="title">管理系统登陆</p>
        <div class="form-item">
            <label class="ri-user-2-line" for="username"></label>
            <input type="text" id="username" name="username" placeholder="请输入用户名" />
        </div>
        <div class="form-item">
            <label class="ri-lock-2-line" for="password"></label>
            <input type="password" id="password" name="password" placeholder="请输入密码" />
        </div>
        <div class="form-item">
            <input type="text" name="captcha" placeholder="请输入验证码"/>
            <img src="/admin/auth/code" title="看不清？点击刷新" onclick="javascript:this.src='/admin/auth/code?t='+Math.random()">
        </div>
        <button type="submit">登 录</button>
    </form>
</section>
</body>
</html>
